# Contributor: Bart Ribbers <bribbers@disroot.org>
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=kde-gtk-config
pkgver=5.19.4
pkgrel=0
pkgdesc="GTK2 and GTK3 Configurator for KDE"
arch="all !armhf" # qtdeclarative
url="https://cgit.kde.org/kde-gtk-config"
license="GPL-2.0 AND LGPL-2.1-only OR LGPL-3.0-only"
depends="gsettings-desktop-schemas"
makedepends="extra-cmake-modules qt5-qtbase-dev qt5-qtsvg-dev ki18n-dev kio-dev kconfigwidgets-dev knewstuff-dev karchive-dev kcmutils-dev kiconthemes-dev gtk+2.0-dev gtk+3.0-dev gsettings-desktop-schemas-dev"
source="https://download.kde.org/stable/plasma/$pkgver/kde-gtk-config-$pkgver.tar.xz"

build() {
	cmake -B build \
		-DCMAKE_BUILD_TYPE=None \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_INSTALL_LIBDIR=lib
	cmake --build build
}

check() {
	cd build
	CTEST_OUTPUT_ON_FAILURE=TRUE ctest
}

package() {
	DESTDIR="$pkgdir" cmake --build build --target install
}
sha512sums="6c1ef3e04879ec205bdb60c0ecd6c21d2869fd62e004e4bcf5c0448522c517d5ce6f4bc8059b742eb36fb0d7fe1285098f15943ebcfdf07686570dbf8e9c5890  kde-gtk-config-5.19.4.tar.xz"
